<script language="javascript" src="<?=ROOT_PATH?>/html/scripts/pub.js"></script>
<script language="javascript" src="<?=ROOT_PATH?>/html/scripts/hdm.js"></script>
<link rel="stylesheet" type="text/css" href="<?=ROOT_PATH?>/html/styles/shop/shop_index.css" media="screen" />
    <div id="rightBody">
    	<div id="centerLeftBody">
			<div class="MiddleBox">
				<div id="centerAd">
					<a href="#"><img id="centerAdImg"  width="570px" height="200px" /></a>    
				</div>
				<div id="adTextDiv"> 
					<div id="innerText">
						<?for($i=0;$i<count($this->imgArray['imgUrl']);$i++):?>
						<a class="ad<?=$i+1?>" href="#"><?=$i+1?></a>
						<?endfor;?>
					</div>
				</div>  
		  	</div>
			<div class="page_box">
                <h3 class="divbg">Product show</h3>
				<div class="productShowDiv" id="movingItem">
					<table style="width:800px;margin-top:5px;" cellpadding="0" cellspace="0" border="0">
					<tr>
						<td style="width:800px" id="movingItem1">
							<table style="width:1100px" border="0" cellspacing="0" cellpadding="0">
								<tr>
									<?foreach($this->isGunItemArray as $value):?>
									<td class="items" align="center">
										<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
										<div><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><?=$this->subStr($value['subject'],0,22)?></a></div>
									</td>
									<?endforeach;?>
								</tr>
							</table>
						</td>
						<td id="movingItem2"></td>
					</tr>
					</table>
				</div>
        	</div>
            <div class="page_box">
                <h3 class="divbg">
				<!--<span><a href="<?=MY_URL?>/category-newproduct/">More...</a></span>-->
				Soccer</h3>
                <div class="productShowDiv">
					<ul>
						<?foreach($this->isHotItemArray as $value):?>
						<li>
						    				
							<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/" target="_blank"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
							<div class="cloths_name"><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/" target="_blank"><?=$this->subStr($value['subject'],0,100)?></a>                            </div>							
							<?if($value['min_price']!=$value['max_price']):?>
								<div class="productPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
							<?else:?>
								<div class="productPrice">$<?=$value['min_price']?></div>
							<?endif;?>
						</li>
						<?endforeach;?>
					</ul>
					<div class="clearthis">.</div>
                </div>
        	</div>	
					
        </div><!--centerLeftBody-->
		
		
        <div id="centerRightBody">
		   	<div class="page_box page_box_bg" >
                <h3>Top sellers</h3>
                <div class="topSellers">
					<ul class="sidenav">
						<?foreach($this->isBestItemArray as $value):?>
						<li>
						    <a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/">							
							<?=$this->subStr($value['subject'],0,50)?>
							<span>
							<img src="<?=MY_URL?>/<?=$value['cut_url']?>" />
						
								<?if($value['min_price']!=$value['max_price']):?>
									<div class="topSellerPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
								<?else:?>
									<div class="topSellerPrice">$<?=$value['min_price']?></div>
								<?endif;?>						
							</span>
							</a>
							<div class="clearthis">.</div>
						</li>
						<?endforeach;?>
					<ul>
				<div class="clearthis">.</div>
				</div><!--topSellers-->
        	</div>
			
		    <div class="page_box scroll">
			
			<!--css在shop.css中,js在html/scripts/product_category.js-->           				
				<div id="tb_" class="tb_">
                    <ul>
                        <li id="tb_1" class="hovertab" onmouseover="x:HoverLi(1);">
                         NBA</li>
                        <li id="tb_2" class="normaltab" onmouseover="i:HoverLi(2);">
                         NFL</li>
                        <li id="tb_3" class="normaltab" onmouseover="a:HoverLi(3);">
                         NHL</li>
                        <li id="tb_4" class="normaltab" onmouseover="o:HoverLi(4);">
                         LED</li>
                    </ul>
                 </div>
				
                <div class="productShowDiv">
				    <div class="dis" id="tbc_01">
					<ul>
						<?foreach($this->nbaitemArray as $value):?>
						<li>
						    
							<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
							<div class="cloths_name"><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><?=$this->subStr($value['subject'],0,100)?></a></div>
							<?if($value['min_price']!=$value['max_price']):?>
								<div class="productPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
							<?else:?>
								<div class="productPrice">$<?=$value['min_price']?></div>
							<?endif;?>
							
						</li>
						<?endforeach;?>
					</ul>
					</div><!--tbc_01-->
					
					<div class="undis" id="tbc_02">
					<ul>
						<?foreach($this->nflitemArray as $value):?>
						<li>
						    
							<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
							<div class="cloths_name"><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><?=$this->subStr($value['subject'],0,100)?></a></div>
							<?if($value['min_price']!=$value['max_price']):?>
								<div class="productPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
							<?else:?>
								<div class="productPrice">$<?=$value['min_price']?></div>
							<?endif;?>
							
						</li>
						<?endforeach;?>
					</ul>
					</div><!--tbc_02-->
					
					<div class="undis" id="tbc_03">
					<ul>
						<?foreach($this->nhlitemArray as $value):?>
						<li>
						    
							<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
							<div class="cloths_name"><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><?=$this->subStr($value['subject'],0,100)?></a></div>
							<?if($value['min_price']!=$value['max_price']):?>
								<div class="productPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
							<?else:?>
								<div class="productPrice">$<?=$value['min_price']?></div>
							<?endif;?>
							
						</li>
						<?endforeach;?>
					</ul>
					</div><!--tbc_03-->
					
					<div class="undis" id="tbc_04">
					<ul>
						<?foreach($this->ChineseitemArray as $value):?>
						<li>
						    
							<a title="<?=$value['pattern_intro']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><img class="productImg" src="<?=MY_URL?>/<?=$value['cut_url']?>" /></a>
							<div class="cloths_name"><a title="<?=$value['subject']?>" href="<?=MY_URL?>/product-detail-id-<?=$value['itemid']?>/<?=$this->encodeName($value['subject'])?>/"><?=$this->subStr($value['subject'],0,100)?></a></div>
							<?if($value['min_price']!=$value['max_price']):?>
								<div class="productPrice">$<?=$value['min_price']?>~<?=$value['max_price']?></div>
							<?else:?>
								<div class="productPrice">$<?=$value['min_price']?></div>
							<?endif;?>
							
						</li>
						<?endforeach;?>
					</ul>
					</div><!--tbc_04-->
					
					<div class="clearthis">.</div>
                </div>
        	</div>

			
			
			
			
			
				 
				 
			

        </div><!--centerRightBody-->
    </div><!--rightBody-->
<script>
  	var imgArray=new Array;
	var hrefArray=new Array;
	<?for($i=0;$i<count($this->imgArray['imgUrl']);$i++):?>
		imgArray.push('<?=$this->imgArray['imgUrl'][$i]?>');
		hrefArray.push('<?=$this->imgArray['imgHref'][$i]?>');
	<?endfor;?>
	adChangeAction.pushArray(imgArray,hrefArray);
  	adChangeAction.run();

	var movingItem = document.getElementById("movingItem");
	var movingItem1 = document.getElementById("movingItem1");
	var movingItem2 = document.getElementById("movingItem2");
	var speed=20;    //滚动速度值，值越大速度越慢
	movingItem2.innerHTML = movingItem1.innerHTML ;   //克隆demo2为demo1
	function Marquee(){
		if(movingItem2.offsetWidth-movingItem.scrollLeft<=0)
		   movingItem.scrollLeft-=movingItem1.offsetWidth
		else{
		   movingItem.scrollLeft++
		}
	}
	var MyMar = setInterval(Marquee,speed);        //设置定时器
	movingItem.onmouseover = function(){clearInterval(MyMar)}   ; //鼠标经过时清除定时器达到滚动停止的目的
	movingItem.onmouseout = function(){MyMar = setInterval(Marquee,speed)}  ;  //鼠标移开时重设定时器
	userPannel.show();
</script>
